#ifndef SEQLIST_H_
#define SEQLIST_H_

#include <stdio.h>
#include <stdlib.h>
#include <assert.h>

typedef int SLDateType;
typedef struct SeList
{
    SLDateType* a;
    int size;     //顺序表有效个数
    int capacity; //动态开辟的容量
} Seqlist;

void SeqlistInit(Seqlist* sql);                             //初始化顺序表
void SeqListCheckCapacity(Seqlist* sql);                    //扩容
void SeqlistDestroy(Seqlist* sql);                          //释放顺序表
void SeqlistPrint(const Seqlist* sql);                      //显示顺序表内容
void SeqlistInsert(Seqlist* sql, size_t pos, SLDateType x); //在下标为pos后一个位置插入一个x值
void SeqlistErase(Seqlist* sql, size_t pos);                //删除下标为pos的内容
void SeqlistPushBack(Seqlist* sql, SLDateType x);           //尾插
void SeqlistPopBack(Seqlist* sql); //尾删
void SeqlistPushFront(Seqlist* sql, SLDateType x); //头插
void SeqlistPopFront(Seqlist* sql); //头删
#endif